#include <functional>
#include "test.hpp"
#include "Log.hpp"
using namespace ThreadPoolModule;
using namespace LogModule;
using task_t = std::function<void()>;
#define PT_PTR ThreadPool<task_t>::GetInstance()

int main()
{
    for (int i = 0; i < 10; i++)
    {
        PT_PTR.PushTask([i]
                        { LOG(LogLevel::INFO) << "正在为同学" << i << "下载原神..."; });
    }
    // PT_PTR->Wait();
    PT_PTR.Stop();
    PT_PTR.Wait();
    LOG(LogLevel::INFO) << "主线程退出";
    return 0;
}


